﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Navigation;
using System.Windows.Shapes;
using University.Workshop.Presenters.Cistern.Read;

namespace University.Workshop.Presentation.Cistern.Read
{
    /// <summary>
    /// Interaction logic for PageSecondStepReadCisternView.xaml
    /// </summary>
    public partial class PageSecondStepReadCisternView : Page, ISecondStepReadCistern
    {
        PresenterReadCistern pInternal;
        PresenterReadSecondStep pReadSecondStep;
        public PageSecondStepReadCisternView(PresenterReadCistern pExternal)
        {
            pInternal = pExternal;
            InitializeComponent();
            pReadSecondStep = new PresenterReadSecondStep(this);
        }
        public void Update()
        {
            pReadSecondStep.UpdateData();
        }

        public void GoNextPage()
        {
            pInternal.GoStepTwo();
        }

        public void GoBackPage()
        {

        }

        public string Capacity
        {
            get
            {
                return CapacityLbl.Content.ToString();
            }
            set
            {
                CapacityLbl.Content = value;
            }
        }

        public string LicensePlate
        {
            get
            {
                return PlateLbl.Content.ToString();
            }
            set
            {
                PlateLbl.Content = value;
            }
        }

        private void Page_Loaded(object sender, RoutedEventArgs e)
        {
            App.Current.MainWindow.Title = "Ver Cisterna";
        }

        public Model.Cistern CisternToRead
        {
            get;
            set;
        }
    }
}
